#pragma once

typedef struct _vus_clip_base vus_clip_base;
typedef struct _vus_clip_list vus_clip_list;

/**
 * Creates a new clip list.
 *
 * @return A non-null clip list.
 */
VENTUS_EXPORT vus_clip_list *vus_clip_list_alloc();

/**
 * Deletes a clip list.
 *
 * @param self The clip list.
 */
VENTUS_EXPORT void vus_clip_list_free(vus_clip_list *self);

/**
 * Adds a clip to a clip list.
 *
 * @param self The clip list.
 * @param value The clip to add.
 */
VENTUS_EXPORT void vus_clip_list_add(vus_clip_list *self, vus_clip_base *value);

/**
 * Removes a clip from a clip list.
 *
 * @param self The clip list.
 * @param value The clip to remove.
 */
VENTUS_EXPORT void vus_clip_list_remove(vus_clip_list *self, vus_clip_base *value);

/**
 * Removes all clips from a clip list.
 *
 * @param self The clip list.
 */
VENTUS_EXPORT void vus_clip_list_clear(vus_clip_list *self);

/**
 * Gets the number of clips in a clip list.
 *
 * @param self The clip list.
 * @return The number of clips in the clip list.
 */
VENTUS_EXPORT uint vus_clip_list_count(vus_clip_list *self);

/**
 * Gets the clip at the specified index.
 *
 * @param self The clip list.
 * @param index The index of the clip to retrieve.
 * @return A non-null clip.
 */
VENTUS_EXPORT vus_clip_base *vus_clip_list_get(vus_clip_list *self, uint index);

/**
 * Sets the clip at the specified index.
 *
 * @param self The clip list.
 * @param index The index of the clip to set.
 * @param value The value to set the clip to.
 */
VENTUS_EXPORT void vus_clip_list_set(vus_clip_list *self, uint index, vus_clip_base *value);

/**
 * Gets the index at which a clip appears in a clip list.
 *
 * @param self The clip list.
 * @param value The value to search for.
 * @return The output index.
 */
VENTUS_EXPORT int vus_clip_list_index_of(vus_clip_list *self, vus_clip_base *value);
